package com.example.springcloudorderprovider.controller;

import com.example.orderapi.api.IOrderService;
import com.example.orderapi.dto.OrderDto;
import org.springframework.web.bind.annotation.RestController;

import java.math.BigDecimal;

/**
 * @author
 * @date 2021-4-16 10:38
 */
@RestController
public class OrderController implements IOrderService {
    @Override
    public OrderDto queryByOrderId(Integer orderId) {
        OrderDto orderDto = new OrderDto();
        orderDto.setNum(1);
        orderDto.setTotalPrice(new BigDecimal(100000));
        orderDto.setOrderId(1);
        orderDto.setUserId(1);
        return orderDto;
    }

    @Override
    public int create(OrderDto orderDto) {
        return 0;
    }
}
